<!DOCTYPE html>
<html>
<head>
<title></title>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
<link href="__STATIC__/bootstrap/css/bootstrap.min.css" rel="stylesheet" media="screen">
<script type="text/javascript" src="__STATIC__/jquery-2.1.3.js"></script>
<script src="__STATIC__/bootstrap/js/bootstrap.min.js"></script>
<css file='__ADMIN_PUBLIC__/css/public.css' />
<style>
body{font-family:'微软雅黑'}
a{cursor:pointer;padding:3px 3px;}
.mt20{margin-top:20px;}
.nav.nav-tabs li{margin:0;padding:0;}
.nav.nav-tabs li a{font-size:16px;font-weight:bold;}
.nav.nav-pills li a{padding:6px 12px;}
.fs16{font-size:16px;}
.fr{float:right;}
.page span{padding:3px 6px;}
.handle a {border-right: 1px solid #bbb; padding: 0 6px;}
</style>
</head>
<body>
    <div class="col-md-12">
    	<h3>活动列表</h3>
    	<div class="col-md-12">
	        <form action="{:U('/Admin/Activity/act_list')}" method="post">
		        <span><input type="text" name="search" class="col-md-3 col-md-offset-7" value="{$search}" placeholder="请输入主题或类型，支持模糊查询" /></span>
		        <input type="hidden" value="{$status}" name="status" />
		        <button class="btn btn-success col-md-1 " type="submit" style="margin: 0 20px;" />搜索</button>
		    </form>
	    </div>
	    <ul class="nav nav-tabs text-center" id="nav">
            <li class="col-md-2 "><a <eq name="status" value="1">class="btn-info"</eq> href="{:U('/Admin/Activity/act_list', array('status' => 1))}">进行中</a></li>
            <li class="col-md-2"><a <eq name="status" value="2">class="btn-info"</eq> href="{:U('/Admin/Activity/act_list', array('status' => 2))}">已结束</a></li>
        </ul>
    </div>
    
    <div class="col-md-12 mt20">
        <table class="table table-striped" style="text-align: center;">
            <tr>
                <th>风格类型</th>
                <th>活动主题</th>
                <th>主题图片</th>
                <th>活动地址</th>
                <th>活动时间</th>
                <th>微信活动报名链接</th>
                <th style="padding-left: 14px;width: 15%;">操作</th>
            </tr>
            <notempty name="act">
            <foreach name='act' item='v'>
            <tr>
            	<td>{$v.type}</td>
                <td>{$v.title}</td>
                <td><img src="{$v.theme}" style="width: 160px;height: 100px;"></td>
                <td>{$v.address}</td>
                <td>{$v.atime|date='m月d日 H:i',###}--{$v.aetime|date='m月d日H:i',###}</td>
                <td style="width: 200px;word-break:break-all">{$v.actshareurl}</td>
                 <td>
                 	<a href="{:U('Activity/act_info', array('id' => $v['id']))}">编辑</a>
                 	<a href="{:U('Activity/act_allinfo', array('id' => $v['id']))}">详情</a>
                 	<if condition="($v.status eq 1) AND ($v.aetime egt time())">
                 		<a href="{:U('Activity/act_cooper_info', array('id' => $v['id']))}">活动合作</a>
                 		<if condition="$v.islb eq 0">
                 			<a href="{:U('Activity/lact_add',array('aid' => $v['id']))}">设置轮播</a>	
                 			<else/>
                 			<a onclick="return confirm('确定要结束此活动轮播?')" href="{:U('Activity/lact_soldout',array('aid' => $v['id']))}">结束轮播</a>
                 		</if>
                 		<a onclick="return confirm('确定要取消该活动?')" href="{:U('Activity/act_soldout', array('id' => $v['id']))}">结束活动</a>
                 	<else/>
                 		<a onclick="return confirm('确定要删除该数据?')"  href="{:U('Activity/act_delect', array('id' => $v['id']))}">删除</a>
                 	</if>
                 </td>
            </tr>
            </foreach>
            <else/>
            <tr>
            	<td colspan="7" class="text-center">暂无数据！！！</td>
            </tr>
            </notempty>
        </table>
    </div>
 <div class="text-center page">{$page}</div>
</body>
</html>